package org.fyv233.missingno_craft.item;

import net.minecraft.item.*;
import net.minecraft.registry.Registries;
import net.minecraft.registry.RegistryKey;
import net.minecraft.util.Identifier;
import org.fyv233.missingno_craft.Missingno_craft;
import org.fyv233.missingno_craft.item.custom.Prospecter;

public class ModItems {

    public static final Item MISSINGNO_INGOT = register("missingno_ingot", new Item(new Item.Settings()));
    public static final Item MISSINGNO_NUGGET = register("missingno_nugget", new Item(new Item.Settings()));

    public static final Item MISSINGNO_PROSPECTER = register("missingno_prospecter", new Prospecter(new Item.Settings().maxDamage(500)));
    public static final Item MISSINGNO_PICKAXE = register("missingno_pickaxe", new PickaxeItem(ModToolMaterials.MISSINGNO_INGOT,
            new Item.Settings().attributeModifiers(PickaxeItem.createAttributeModifiers(ModToolMaterials.MISSINGNO_INGOT, 1.5f, -2.8f)).fireproof()));
    public static final Item MISSINGNO_AXE = register("missingno_axe", new AxeItem(ModToolMaterials.MISSINGNO_INGOT,
            new Item.Settings().attributeModifiers(AxeItem.createAttributeModifiers(ModToolMaterials.MISSINGNO_INGOT, 1.5f, -2.8f)).fireproof()));
    public static final Item MISSINGNO_SWORD = register("missingno_sword", new SwordItem(ModToolMaterials.MISSINGNO_INGOT,
            new Item.Settings().attributeModifiers(SwordItem.createAttributeModifiers(ModToolMaterials.MISSINGNO_INGOT, 5, -3.0f)).fireproof()));
    public static final Item MISSINGNO_HOE = register("missingno_hoe", new HoeItem(ModToolMaterials.MISSINGNO_INGOT,
            new Item.Settings().attributeModifiers(HoeItem.createAttributeModifiers(ModToolMaterials.MISSINGNO_INGOT, 15, -3.0f)).fireproof()));

    public static final Item MISSINGNO_HELMET = register("missingno_helmet", new ArmorItem(ModArmorMaterials.MISSINGNO, ArmorItem.Type.HELMET,
            new Item.Settings().fireproof().maxDamage(ArmorItem.Type.HELMET.getMaxDamage(50))));

    public static final Item MISSINGNO_CHESTPLATE = register("missingno_chestplate", new ArmorItem(ModArmorMaterials.MISSINGNO, ArmorItem.Type.CHESTPLATE,
            new Item.Settings().fireproof().maxDamage(ArmorItem.Type.CHESTPLATE.getMaxDamage(50))));

    public static final Item MISSINGNO_BOOTS = register("missingno_boots", new ArmorItem(ModArmorMaterials.MISSINGNO, ArmorItem.Type.BOOTS,
            new Item.Settings().fireproof().maxDamage(ArmorItem.Type.BOOTS.getMaxDamage(50))));

    public static final Item MISSINGNO_LEGGINGS = register("missingno_leggings", new ArmorItem(ModArmorMaterials.MISSINGNO, ArmorItem.Type.LEGGINGS,
            new Item.Settings().fireproof().maxDamage(ArmorItem.Type.LEGGINGS.getMaxDamage(50))));

    public static Item register(String id, Item item){
    return Items.register(RegistryKey.of(Registries.ITEM.getKey(), Identifier.of(Missingno_craft.MOD_ID, id)), item);
    }

    public static void registerModItems() {}
}
